#ifndef MEDICALRECORDDETAILWIDGET_H
#define MEDICALRECORDDETAILWIDGET_H

#include <QWidget>
#include "../../../Common/models.h"
#include "../../../Common/protocol.h"

namespace Ui {
class MedicalRecordDetailWidget;
}

class MedicalRecordDetailWidget : public QWidget {
    Q_OBJECT
    
public:
    explicit MedicalRecordDetailWidget(const MedicalRecord& record, QWidget *parent = nullptr);
    ~MedicalRecordDetailWidget();
    
private slots:
    void on_viewPrescriptionButton_clicked();
    void onMessageReceived(MessageType type, const QJsonObject& data);
    
private:
    Ui::MedicalRecordDetailWidget *ui;
    MedicalRecord m_record;
};

#endif // MEDICALRECORDDETAILWIDGET_H

